feat: use oxlint for faster lint#125
Conversation
refactor(lint): migrate linting setup to use oxlint as primary tool refactor(lint): configure ESLint to work alongside oxlint refactor(lint): update package scripts to use new linting commands chore(deps): add oxlint and related packages style(code): suppress oxlint warnings in generated/suppressed files refactor(code): remove redundant ESLint disables where oxlint handles it refactor(code): update character store sorting logic to use object access refactor(code): simplify hook service replacement logic refactor(code): update worker client proxy call for logging refactor(code): update LLM config ID generation refactor(code): remove unused imports and simplify component logic refactor(test): update test assertions to use oxlint disables refactor(test): update mock implementations to suppress oxlint warnings refactor(test): update integration test to use eval safely in mock worker refactor(test): update chat store mock to suppress warnings refactor(test): update hook service test context access refactor(test): update LangChain provider test to suppress warnings refactor(test): update streaming test to use assert and suppress warnings refactor(test): update vite config to suppress warnings in path replacement
Summary of ChangesHello @concertypin, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces Oxlint into the project's frontend for enhanced linting performance. The change establishes a hybrid linting environment, where Oxlint takes precedence for general JavaScript and TypeScript files, while ESLint continues to cover specific use cases like Svelte templates. This strategic integration aims to improve developer experience by providing faster feedback during development and ensuring code quality more efficiently. Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
✅ Deploy Preview for arisutalk-preview ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
There was a problem hiding this comment.
Code Review
This pull request successfully introduces oxlint for faster linting, which is a great improvement for the development workflow. The configuration is well-structured across several new files, and the npm scripts are updated accordingly. I appreciate the addition of documentation in frontend/docs/rules/tools.md to explain the new setup.
The changes also include several small but valuable code quality improvements, such as adding cause to thrown errors for better debugging and refactoring code for improved readability.
I have one suggestion regarding the new linting scripts to better align with the repository's guidelines for local development performance. Overall, this is a solid contribution.
- Restructured ESLint to target only Svelte files for performance improvement. - Configured Oxlint as the primary linter for pure TS/JS files. - Fixed Svelte 5 false positives by adjusting rune declarations. - Optimized incremental linting by avoiding global negation patterns.
…ite.config.ts refactor(deps): move Vitest configuration to dedicated script for better organization refactor(deps): update ESLint configuration to use Prettier as default formatter for Svelte refactor(deps): simplify test scripts and remove browser-specific test commands refactor(deps): update ESLint and OXLint configurations for stricter error reporting refactor(deps): update tsconfig.common.json to include scripts directory refactor(deps): update tsconfig.test.json to use explicit paths and remove redundant settings refactor(deps): update component state declarations to use `let` instead of `const` for reactive variables refactor(deps): update test paths to use alias for wrapper component test(config): introduce dedicated browser test configuration file for Vitest test(provider): annotate GeminiChatProvider connection test for better debugging
ddbac75 to
0217711
Compare
|
Current workload looks not flaky. Action log |
This change refactors the monolithic CI workflow (`ci.yml`) into two dedicated workflows: `backend_ci.yml` and `frontend_ci.yml`. The previous setup was inefficient as it ran all checks (build, lint, test, coverage) for both parts in a single run, often leading to long execution times and unnecessary dependency installations if only one part changed. The new structure allows: 1. **Backend CI (`backend_ci.yml`):** Focuses only on backend build checks, triggered on PRs to `main` and `kei`. 2. **Frontend CI (`frontend_ci.yml`):** Handles frontend linting, type checking, unit/browser testing (sharded), and coverage reporting. It is triggered only when frontend files or related config change. 3. **Improved Efficiency:** Faster feedback loops by running only relevant checks. 4. **Test Sharding:** The frontend tests are now sharded across multiple jobs (`tests` job) for faster execution, with a dedicated `merge-reports` job to combine results and update status checks. The old `ci.yml` is removed, and VS Code settings related to Vitest environment variables are cleaned up as they are no longer needed for the new CI structure. Node engine requirement in `package.json` is also updated to be more specific.
Refactor CI workflows to trigger based on changes in specific directories (`backend/**` or `frontend/**`) and workflow files, rather than specific branches. This ensures CI runs when relevant code changes, regardless of the target branch name.
…lint parser options Removes the duck-typed `TypescriptParserOptions` type definition and the `satisfies` clause. This is done because the type assertion was likely added to work around issues with pnpm hoisting, but it adds unnecessary complexity and might be outdated. ESLint configuration should rely on standard object structure.
89f9bc3 to
71caa9e
Compare
71caa9e to
bb79ad2
Compare
Benchmark InformationVM creation command for benchmarkgcloud compute instances create benchmark \
--zone=us-central1-f \
--machine-type=c4-highcpu-4 \
--network-interface=network-tier=STANDARD,nic-type=GVNIC,stack-type=IPV4_ONLY,subnet=default \
--no-restart-on-failure \
--maintenance-policy=TERMINATE \
--provisioning-model=SPOT \
--instance-termination-action=STOP \
--max-run-duration=10800s \
--no-service-account \
--no-scopes \
--min-cpu-platform=Intel\ \
Emerald\ Rapids \
--create-disk=auto-delete=yes,boot=yes,device-name=benchmark,image=projects/debian-cloud/global/images/debian-12-bookworm-v20260210,mode=rw,provisioned-iops=3000,provisioned-throughput=140,size=15,type=hyperdisk-balanced \
--no-shielded-secure-boot \
--shielded-vtpm \
--shielded-integrity-monitoring \
--labels=goog-ec-src=vm_add-gcloud \
--reservation-affinity=none \
--threads-per-core=2 \
--turbo-mode=ALL_CORE_MAXESLint only setupESLint(Svelte)+oxlint(other TypeScript) setup |
Updates various dependencies in `frontend/package.json` to their latest versions. This is done to incorporate bug fixes, performance improvements, and new features from the underlying libraries used in the frontend application. Also updates test configuration in `frontend/scripts/testConfig.ts` to explicitly include test directories instead of relying on exclusion patterns, improving clarity and robustness of test discovery.


Pull Request Template
Description
Introducing oxlint for faster linting.
Checklist
If these questions do not apply to your pull request, just check them.
Additional Notes
Benchmark needed.